//
//  CSL_CollecCell.m
//  HZ_Beautiful_Music
//
//  Created by dllo on 16/4/12.
//  Copyright © 2016年 ui. All rights reserved.
//

#import "CSL_CollecCell.h"

@implementation CSL_CollecCell
-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.mvImageView = [[UIImageView alloc] initWithFrame:CGRectZero];
        _mvImageView.backgroundColor = [UIColor redColor];
        [self.contentView addSubview:_mvImageView];
        
        self.titleLabel = [[UILabel alloc] initWithFrame:CGRectZero];
//        _titleLabel.backgroundColor = [UIColor redColor];
        _titleLabel.text = @"gtunhhuhhngtrijnog";
        _titleLabel.font = [UIFont systemFontOfSize:16];
//        _titleLabel.textColor = [UIColor grayColor];
        _titleLabel.textAlignment = NSTextAlignmentCenter;
        [self.contentView addSubview:_titleLabel];
        
        self.nameLabel = [[UILabel alloc] initWithFrame:CGRectZero];
//        _nameLabel.backgroundColor = [UIColor redColor]
        _nameLabel.text = @"birtjgijre";
        _nameLabel.textColor = [UIColor grayColor];
        _nameLabel.font = [UIFont systemFontOfSize:15];
        _nameLabel.textAlignment = NSTextAlignmentCenter;
        [self.contentView addSubview:_nameLabel];
        
        self.footView = [[UIView alloc] initWithFrame:CGRectZero];
        _footView.backgroundColor = [UIColor colorWithWhite:0.897 alpha:1.000];
        [self.contentView addSubview:_footView];        
    }
    return self;
}

-(void)layoutSubviews {
    [super layoutSubviews];
    _mvImageView.frame = CGRectMake(self.bounds.size.width/20, self.bounds.size.height/10, self.bounds.size.width/4, self.bounds.size.height/1.2);
    _titleLabel.frame = CGRectMake(self.bounds.size.width/3, self.bounds.size.height/7, self.bounds.size.width/2, self.bounds.size.height/3);
    _nameLabel.frame = CGRectMake(self.bounds.size.width/3, self.bounds.size.height/1.6, self.bounds.size.width/2, self.bounds.size.height/4);
    _footView.frame = CGRectMake(0, self.bounds.size.height - 1, self.bounds.size.width, 1);
    
}

@end
